<?php

if (!function_exists('is_plugin_active')) {
    require_once(ABSPATH . 'wp-admin/includes/plugin.php');
}

if (!is_plugin_active('markup-markdown/markup-markdown.php')) {
    add_action('admin_notices', 'wptovp_markdown_plugin_notice');
}

function wptovp_markdown_plugin_notice() {
    ?>
        <div class="notice notice-error">
            <p><?php _e('wptovp插件必须要安装Markup Markdown插件才能运行正常！', wp_to_vp_textdomain); ?></p>
        </div>
    <?php
}